package ru.reinvent.perspectiva.cash;

import java.util.ArrayList;

public class Vendor 
	{
	private int id = -1;
	private String name = null;
	private ArrayList<Lot> lots = null;
	
	public int getId() { return id; }
	public String getName() { return name; }
	public Lot getLot(int index) { return lots.get(index); }
	public ArrayList<Lot> getLots() 
		{ 
		if (lots == null) lots = new ArrayList<Lot>();
		return lots; 
		}
	
	public void setId(int id) { this.id = id; }
	public void setName(String name) { this.name = name; }
	public void setLots(ArrayList<Lot> lots) { this.lots = lots; }
	public void addLot(Lot lot) 
		{
		if (lots == null) lots = new ArrayList<Lot>();
		lots.add(lot);
		}
	}
